import request from '@/utils/request'

// 查询菜单列表
export function menuList(query?: any) {
    return request({
        url: '/api/v1/admin/system/menu/list',
        method: 'get',
        params: query
    })
}

// 新增菜单
export function menuAdd(data: any) {
    return request({
        url: '/api/v1/admin/system/menu/add',
        method: 'post',
        data: data
    })
}

// 编辑菜单
export function menuEdit(data: any) {
    return request({
        url: '/api/v1/admin/system/menu/edit',
        method: 'post',
        data: data
    })
}

// 删除菜单
export function menuRemove(id: number) {
    return request({
        url: '/api/v1/admin/system/menu/remove',
        method: 'delete',
        data: id
    })
}